﻿@model SpaceNeedle.City6473.WebSite.Models.AlertsModel
@using SpaceNeedle.City6473.Web.Data.Models

@{
    Layout = "~/Views/Shared/_Layout.cshtml";

    var staticContent = ViewBag.StaticContent as WebSiteContent;
    ViewBag.Title = staticContent.Alerts.PageTitle;
}

<table style="width:960px;">
    <tr>
        <th style="text-align:left">
            @staticContent.Alerts.Title
        </th>
        <th style="text-align:left">
            @staticContent.Alerts.Description
        </th>
        <th>

        </th>
    </tr>

    @foreach (var item in Model.Alerts)
    {
        <tr>
            <td>
                @item.Title
            </td>
            <td>
                @item.Description
            </td>
            <td>
                <a href="/admin/deletealert/@item.Id" onclick="return confirm('@string.Format(staticContent.Operations.DeleteMessage, item.Title)')" title="@staticContent.Operations.Delete" style="font-family:'Segoe UI Symbol';font-size:18px;">@Html.Raw(staticContent.Operations.DeleteSymbol)</a>
            </td>
        </tr>
    }
</table>

<br /><br />
<h3>@staticContent.Alerts.New</h3>
@using (Html.BeginForm())
{
    @*@Html.Hidden("Id", NewPhone.Id)*@
    
    <div class="editor-label">
        @staticContent.Alerts.Title
    </div>
    <div class="editor-field">
        @Html.TextBoxFor(model => model.Title,new { @class = "form-control" })
        @Html.ValidationMessageFor(model => model.Title)
    </div>
    <br />

    <div class="editor-label">
        @staticContent.Alerts.Description
    </div>
    <div class="editor-field">
        @Html.TextBoxFor(model => model.Description, new { @class = "form-control" })
        @Html.ValidationMessageFor(model => model.Description)
    </div>
    <br />


    <br />
    <div>
        <button class="btn btn-default" type="submit" value="Create">
            @staticContent.Operations.Add
        </button>
    </div>
    
    

}


